import os
path = "."
filelist = os.listdir(path)
#print(filelist)
for f in filelist:
    cur = path + "//" + f  
    upd = cur.replace("sid", "pid")
    if cur != upd:
        cmd = "xyz mv " + cur + " " + upd
        print(cmd)
        os.system(cmd)